package com.yingxin.yx.framework.commons.enums;

/**
 * 拉矫状态枚举
 */

public enum RectifyStatusEnums {

    ZERO("0", "正常"),
    IN_LJ_APPLY("IN_LJ_APPLY", "拉矫申请中"),
    IN_LJ_PENDING("IN_LJ_PENDING", "拉矫待出库"),
    IN_LJ_STOCK_OUT("IN_LJ_STOCK_OUT", "拉矫出库");

    private String type;

    private String typeName;

    RectifyStatusEnums(String type, String typeName) {
        this.type = type;
        this.typeName = typeName;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getTypeName() {
        return typeName;
    }

    public void setTypeName(String typeName) {
        this.typeName = typeName;
    }

    public static RectifyStatusEnums getEnum(String type) {
        if (type == null) {
            return null;
        }
        for (RectifyStatusEnums i : RectifyStatusEnums.values()) {
            if (i.getType().equals(type)) {
                return i;
            }
        }
        return null;
    }

}
